﻿
using System;
namespace WPTrek.Data.Space
{
    public class Sector : ISector
    {
        public Sector(Guid id, int x, int y, string name, IGalaxy parent)
        {
            if (parent == null)
                throw new NullReferenceException("Illegal null-reference parent galaxy");

            this.id = id;
            this.x = x;
            this.y = y;
            this.name = name;
            this.parent = parent;
        }

        #region ISector Members

        public Guid ID
        {
            get
            {
                return id;
            }
        }

        public int X
        {
            get
            {
                return x;
            }
        }

        public int Y
        {
            get
            {
                return y;
            }
        }

        public string Name
        {
            get
            {
                return name;
            }
        }

        public IGalaxy Parent
        {
            get
            {
                return parent;
            }
        }

        #endregion

        private IGalaxy parent;
        private Guid id;
        private string name;
        private int x;
        private int y;
    }
}
